package com.sz.mes.vo.warehouse;

import com.diboot.core.binding.annotation.*;
import com.sz.mes.entity.warehouse.InstockRecord;
import com.sz.mes.entity.Instock;
import com.sz.mes.entity.warehouse.Lattice;
import com.sz.mes.entity.Goods;
import com.diboot.iam.entity.IamUser;
import lombok.Getter;
import lombok.Setter;
import lombok.experimental.Accessors;
import java.util.List;

/**
 * 入库记录 ListVO定义
 * @author hem
 * @version 1.0
 * @date 2023-05-25
 * Copyright © szhs
 */
@Getter
@Setter
@Accessors(chain = true)
public class InstockRecordListVO extends InstockRecord {

    private static final long serialVersionUID = -9160061223526467621L;

    /**
     * 关联字段 位置详情：Lattice.label
     */
    @BindField(entity = Lattice.class, field = "label", condition = "this.warehouse_lattice_id=id")
    private String warehouseLatticeLabel;

    /**
     * 关联字段 商品表.商品名称：Goods.goodsName
     */
    @BindField(entity = Goods.class, field = "goodsName", condition = "this.goods_id=id")
    private String goodsGoodsName;

    /**
     * 关联字典：RECEIPT_TYPE
     */
    @BindDict(type = DICT_RECEIPT_TYPE, field = "type")
    private String typeLabel;

    /**
     * 关联字段 系统用户.真实姓名：IamUser.realname
     */
    @BindField(entity = IamUser.class, field = "realname", condition = "this.create_by=id")
    private String createByName;

    /**
     * 关联字段 系统用户.真实姓名：IamUser.realname
     */
    @BindField(entity = IamUser.class, field = "realname", condition = "this.update_by=id")
    private String updateByName;
}
